package ru.spbau.database.group3.indexes.btree;

public class BtreeTest {

	public static void main(String[] args) {
		BPlusTree<Integer, String> testTree = new BPlusTree<Integer, String>(5);
		testTree.insert(1, "1");
		System.out.println(testTree);
		testTree.insert(2, "2");
		System.out.println(testTree);
		testTree.insert(0, "0");
		System.out.println(testTree);
		testTree.insert(3, "3");
		System.out.println(testTree);
		testTree.insert(4, "4");
		System.out.println(testTree);
		testTree.insert(5, "5");
		System.out.println(testTree);
		testTree.insert(6, "6");
		System.out.println(testTree);
		testTree.insert(7, "7");
		System.out.println(testTree);
		testTree.insert(8, "8");
		System.out.println(testTree);
		System.out.println("3 =" + testTree.search(3));
		System.out.println("7 =" + testTree.search(7));
		System.out.println("1 =" + testTree.search(1));
		System.out.println("100 =" + testTree.search(100));
		System.out.println(testTree);
		testTree.delete(1);
		System.out.println(testTree);
		testTree.delete(3);
		System.out.println(testTree);
		testTree.delete(6);
		System.out.println(testTree);
		testTree.delete(7);
		System.out.println(testTree);
		testTree.insert(10, "10");
		System.out.println(testTree);
		testTree.insert(1, "1");
		System.out.println(testTree);
		testTree.insert(11, "11");
		System.out.println(testTree);
		testTree.insert(100500, "100500");
		System.out.println(testTree);
		testTree.insert(9001, "9001");
		System.out.println(testTree);
		testTree.delete(0);
		System.out.println(testTree);
	}
}
